@zonos/elements 1.3.171 → 1.3.172

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (121) hide show
  1. package/dist/cjs/{CheckoutConfig-f5e68e14.js → CheckoutConfig-c5943bbf.js} +1 -1
  2. package/dist/cjs/{cart-36799bbe.js → cart-d91d9507.js} +13 -8
  3. package/dist/cjs/{handleFetch-7b7f9f7c.js → handleFetch-ff25db40.js} +10 -6
  4. package/dist/cjs/index.cjs.js +9 -9
  5. package/dist/cjs/loader.cjs.js +1 -1
  6. package/dist/cjs/{paypal-3eae38bd.js → paypal-82841277.js} +2 -2
  7. package/dist/cjs/zonos-address_7.cjs.entry.js +51 -18
  8. package/dist/cjs/zonos-cart-items_13.cjs.entry.js +10 -6
  9. package/dist/cjs/zonos-checkout.cjs.entry.js +104 -34
  10. package/dist/cjs/zonos-controller.cjs.entry.js +2 -2
  11. package/dist/cjs/zonos-country-flag.cjs.entry.js +2 -2
  12. package/dist/cjs/zonos-country-select_4.cjs.entry.js +2 -2
  13. package/dist/cjs/zonos-elements.cjs.js +1 -1
  14. package/dist/cjs/zonos-empty-state-payment_4.cjs.entry.js +3 -3
  15. package/dist/cjs/zonos-hello-dialog.cjs.entry.js +2 -2
  16. package/dist/cjs/zonos-hello.cjs.entry.js +2 -2
  17. package/dist/cjs/zonos-language-select_2.cjs.entry.js +2 -2
  18. package/dist/collection/components/checkout/zonos-checkout/zonos-checkout.js +112 -35
  19. package/dist/collection/components/checkout/zonos-checkout/zonos-customer-info/zonos-customer-info.js +10 -6
  20. package/dist/collection/components/store/checkout/cart.js +5 -0
  21. package/dist/collection/components/store/checkout/stripe.js +5 -7
  22. package/dist/collection/components/stripe/zonos-address/zonos-address.js +26 -15
  23. package/dist/collection/components/stripe/zonos-link-authentication/zonos-link-authentication.js +27 -4
  24. package/dist/collection/components/utils/handleFetch.js +9 -6
  25. package/dist/collection/components/utils/logging/getAdditionalLogMetadata.js +1 -0
  26. package/dist/collection/styles/stripe/defaultVariable.js +2 -0
  27. package/dist/collection/types/generated/graphql.internal.types.js +7 -0
  28. package/dist/esm/{CheckoutConfig-2994efd9.js → CheckoutConfig-75af3742.js} +1 -1
  29. package/dist/esm/{cart-b2e57589.js → cart-52e208cc.js} +13 -8
  30. package/dist/esm/{handleFetch-8d72c8cd.js → handleFetch-0109fb78.js} +10 -6
  31. package/dist/esm/index.js +10 -10
  32. package/dist/esm/loader.js +1 -1
  33. package/dist/esm/{paypal-38da5d52.js → paypal-2e1c560e.js} +2 -2
  34. package/dist/esm/zonos-address_7.entry.js +51 -18
  35. package/dist/esm/zonos-cart-items_13.entry.js +10 -6
  36. package/dist/esm/zonos-checkout.entry.js +104 -34
  37. package/dist/esm/zonos-controller.entry.js +2 -2
  38. package/dist/esm/zonos-country-flag.entry.js +2 -2
  39. package/dist/esm/zonos-country-select_4.entry.js +2 -2
  40. package/dist/esm/zonos-elements.js +1 -1
  41. package/dist/esm/zonos-empty-state-payment_4.entry.js +3 -3
  42. package/dist/esm/zonos-hello-dialog.entry.js +2 -2
  43. package/dist/esm/zonos-hello.entry.js +2 -2
  44. package/dist/esm/zonos-language-select_2.entry.js +2 -2
  45. package/dist/esm-es5/{CheckoutConfig-2994efd9.js → CheckoutConfig-75af3742.js} +1 -1
  46. package/dist/esm-es5/{cart-b2e57589.js → cart-52e208cc.js} +1 -1
  47. package/dist/esm-es5/handleFetch-0109fb78.js +1 -0
  48. package/dist/esm-es5/index.js +1 -1
  49. package/dist/esm-es5/loader.js +1 -1
  50. package/dist/esm-es5/{paypal-38da5d52.js → paypal-2e1c560e.js} +1 -1
  51. package/dist/esm-es5/zonos-address_7.entry.js +1 -1
  52. package/dist/esm-es5/zonos-cart-items_13.entry.js +1 -1
  53. package/dist/esm-es5/zonos-checkout.entry.js +1 -1
  54. package/dist/esm-es5/zonos-controller.entry.js +1 -1
  55. package/dist/esm-es5/zonos-country-flag.entry.js +1 -1
  56. package/dist/esm-es5/zonos-country-select_4.entry.js +1 -1
  57. package/dist/esm-es5/zonos-elements.js +1 -1
  58. package/dist/esm-es5/zonos-empty-state-payment_4.entry.js +1 -1
  59. package/dist/esm-es5/zonos-hello-dialog.entry.js +1 -1
  60. package/dist/esm-es5/zonos-hello.entry.js +1 -1
  61. package/dist/esm-es5/zonos-language-select_2.entry.js +1 -1
  62. package/dist/scripts/index.d.ts +25 -6
  63. package/dist/scripts/index.js +1 -1
  64. package/dist/scripts/loadZonos.js +1 -1
  65. package/dist/scripts/zonos.js +1 -1
  66. package/dist/types/components/checkout/zonos-checkout/zonos-checkout.d.ts +17 -3
  67. package/dist/types/components/checkout/zonos-checkout/zonos-customer-info/zonos-customer-info.d.ts +1 -1
  68. package/dist/types/components/store/checkout/cart.d.ts +4 -0
  69. package/dist/types/components/store/checkout/stripe.d.ts +10 -1
  70. package/dist/types/components/stripe/zonos-address/zonos-address.d.ts +2 -2
  71. package/dist/types/components/stripe/zonos-link-authentication/zonos-link-authentication.d.ts +1 -1
  72. package/dist/types/components/utils/api/getLocaleMessages.d.ts +1 -1
  73. package/dist/types/components/utils/logging/getAdditionalLogMetadata.d.ts +1 -0
  74. package/dist/types/components.d.ts +8 -6
  75. package/dist/types/types/checkout/CheckoutConfig.d.ts +1 -0
  76. package/dist/types/types/checkout/api/CheckoutSession.d.ts +8 -0
  77. package/dist/types/types/generated/graphql.frontend.types.d.ts +1 -1
  78. package/dist/types/types/generated/graphql.frontend.types.ts +1 -1
  79. package/dist/types/types/generated/graphql.internal.types.d.ts +92 -0
  80. package/dist/types/types/generated/graphql.internal.types.ts +105 -0
  81. package/dist/zonos-elements/assets/RemoveIcon.svg +1 -1
  82. package/dist/zonos-elements/index.esm.js +1 -1
  83. package/dist/zonos-elements/{p-56a8b1f6.system.entry.js → p-048e4b38.system.entry.js} +1 -1
  84. package/dist/zonos-elements/p-04c38987.system.js +1 -0
  85. package/dist/zonos-elements/{p-bf113a46.system.js → p-0ee42be2.system.js} +1 -1
  86. package/dist/zonos-elements/{p-ff1c6d9a.entry.js → p-10a9edf6.entry.js} +1 -1
  87. package/dist/zonos-elements/{p-864c7c7d.entry.js → p-14bd4766.entry.js} +1 -1
  88. package/dist/zonos-elements/{p-47f79a6d.js → p-1c488ecf.js} +1 -1
  89. package/dist/zonos-elements/{p-cb52cfdf.entry.js → p-1e3e4e22.entry.js} +1 -1
  90. package/dist/zonos-elements/p-221d4f15.system.entry.js +1 -0
  91. package/dist/zonos-elements/{p-e09cea9c.entry.js → p-246c3b28.entry.js} +1 -1
  92. package/dist/zonos-elements/p-2b8c5669.system.entry.js +1 -0
  93. package/dist/zonos-elements/{p-dd0259f4.js → p-2d2c70a3.js} +1 -1
  94. package/dist/zonos-elements/{p-c5c2976f.system.js → p-2ebb4fa7.system.js} +1 -1
  95. package/dist/zonos-elements/{p-a3888f1d.system.js → p-36c35a07.system.js} +1 -1
  96. package/dist/zonos-elements/p-46f6e5e9.system.js +1 -1
  97. package/dist/zonos-elements/{p-00ad3c73.entry.js → p-588ac238.entry.js} +1 -1
  98. package/dist/zonos-elements/{p-b0c39400.entry.js → p-68304407.entry.js} +1 -1
  99. package/dist/zonos-elements/{p-ecd4ec15.system.js → p-7de48475.system.js} +1 -1
  100. package/dist/zonos-elements/p-839448c3.js +1 -0
  101. package/dist/zonos-elements/{p-53cb8867.system.entry.js → p-85d2da79.system.entry.js} +1 -1
  102. package/dist/zonos-elements/{p-1a20922f.system.entry.js → p-91a7ca64.system.entry.js} +1 -1
  103. package/dist/zonos-elements/{p-0bfca3a9.system.entry.js → p-9a10a63b.system.entry.js} +1 -1
  104. package/dist/zonos-elements/p-a08fad84.entry.js +1 -0
  105. package/dist/zonos-elements/{p-bfa028a2.entry.js → p-a61ef92f.entry.js} +1 -1
  106. package/dist/zonos-elements/{p-0def1397.system.entry.js → p-aa754137.system.entry.js} +1 -1
  107. package/dist/zonos-elements/{p-c82f488b.system.entry.js → p-aea22783.system.entry.js} +1 -1
  108. package/dist/zonos-elements/p-ba604bc4.entry.js +1 -0
  109. package/dist/zonos-elements/{p-48173901.js → p-bbf9dbe4.js} +1 -1
  110. package/dist/zonos-elements/{p-461ca324.entry.js → p-c719434a.entry.js} +1 -1
  111. package/dist/zonos-elements/{p-56758218.system.entry.js → p-e34c0f83.system.entry.js} +1 -1
  112. package/dist/zonos-elements/{p-1edbfb1f.system.entry.js → p-eb716dcc.system.entry.js} +1 -1
  113. package/dist/zonos-elements/zonos-elements.esm.js +1 -1
  114. package/package.json +1 -1
  115. package/dist/esm-es5/handleFetch-8d72c8cd.js +0 -1
  116. package/dist/zonos-elements/p-173d1fcd.system.entry.js +0 -1
  117. package/dist/zonos-elements/p-71539c8a.js +0 -1
  118. package/dist/zonos-elements/p-9261869c.system.js +0 -1
  119. package/dist/zonos-elements/p-934164df.entry.js +0 -1
  120. package/dist/zonos-elements/p-9f9e4f74.entry.js +0 -1
  121. package/dist/zonos-elements/p-fd352222.system.entry.js +0 -1
@@ -1,6 +1,6 @@
1
1
  'use strict';
2
2
 
3
- const handleFetch = require('./handleFetch-7b7f9f7c.js');
3
+ const handleFetch = require('./handleFetch-ff25db40.js');
4
4
 
5
5
  const getTempCartById = async ({ cartId, retries, }) => {
6
6
  const isTestMode = handleFetch.getIsTestMode();
@@ -1,7 +1,7 @@
1
1
  'use strict';
2
2
 
3
3
  const zonosStore = require('./zonosStore-3812b318.js');
4
- const handleFetch = require('./handleFetch-7b7f9f7c.js');
4
+ const handleFetch = require('./handleFetch-ff25db40.js');
5
5
  const isDarkColor = require('./isDarkColor-ec4a4e7d.js');
6
6
  const getBorderRadius = require('./getBorderRadius-94ef609c.js');
7
7
 
@@ -10942,6 +10942,8 @@ const defaultVariable = ({ borderStyle, theme, }) => {
10942
10942
  default:
10943
10943
  return {
10944
10944
  borderRadius: getBorderRadius.getBorderRadius({ overrideBorderStyle: borderStyle }),
10945
+ iconMenuColor: 'var(--colorText)',
10946
+ iconMenuHoverColor: 'var(--colorText)',
10945
10947
  };
10946
10948
  }
10947
10949
  };
@@ -10951,6 +10953,7 @@ const { onChange: onChange$1, reset: reset$1, state: stripeStore, } = zonosStore
10951
10953
  clientSecret: sessionStorage.getItem('zonos--client-secret') || '',
10952
10954
  companyName: '',
10953
10955
  customErrorMessage: null,
10956
+ customerProfile: null,
10954
10957
  fetchingLandedCostAbortController: null,
10955
10958
  hasPaymentError: false,
10956
10959
  isFetchingLandedCost: false,
@@ -10973,6 +10976,7 @@ const { onChange: onChange$1, reset: reset$1, state: stripeStore, } = zonosStore
10973
10976
  stripeBillingAddressEventData: null,
10974
10977
  stripeBillingAddressUsedWhenFetchingLC: null,
10975
10978
  stripeBillingAddressUsedWhenValidatingAddress: null,
10979
+ stripeCustomerSessionClientSecret: null,
10976
10980
  stripeElements: null,
10977
10981
  stripeElementsForBillingAddress: null,
10978
10982
  stripeElementsOptions: null,
@@ -11014,6 +11018,7 @@ const getStripeOptions = ({ clientSecret, overrideBorderRadius, overridePrimaryC
11014
11018
  },
11015
11019
  // Client secret can be undefined since we will load other elements that doesn't require client secret first, then load client secret and render one that requires it later
11016
11020
  clientSecret: clientSecret || undefined,
11021
+ customerSessionClientSecret: stripeStore.stripeCustomerSessionClientSecret || undefined,
11017
11022
  externalPaymentMethodTypes: [...paypalPaymentType],
11018
11023
  locale: localizationStore.selectedLocale,
11019
11024
  };
@@ -11469,6 +11474,7 @@ const getCheckoutSessionBody = () => {
11469
11474
  adjustmentsAmount: cartStore.adjustments.reduce((prev, adj) => prev + adj.amount, 0),
11470
11475
  cartId: window.Zonos.cartId,
11471
11476
  currency: ((_a = cartStore.items.find(Boolean)) === null || _a === void 0 ? void 0 : _a.currencyCode) || '',
11477
+ customerAuthenticationToken: cartStore.customerAuthenticationToken || undefined,
11472
11478
  itemsAmount: total,
11473
11479
  metadata: [
11474
11480
  {
@@ -11495,10 +11501,6 @@ const getCheckoutSessionBody = () => {
11495
11501
  };
11496
11502
  const stripeStoreGetPaymentIntent = async () => {
11497
11503
  var _a;
11498
- if (stripeStore.clientSecret) {
11499
- handleFetch.log('Payment intent already exists, skipping fetching payment intent');
11500
- return;
11501
- }
11502
11504
  if (!cartStore.checkoutSessionId) {
11503
11505
  // We want to log the error anytime we fail to create a checkout session
11504
11506
  void handleFetch.sendErrorLog({
@@ -11545,9 +11547,6 @@ const stripeStoreGetPaymentIntent = async () => {
11545
11547
  });
11546
11548
  return;
11547
11549
  }
11548
- // update stripe store with updated information
11549
- stripeStore.clientSecret =
11550
- json.checkoutSessionPaymentIntentCreate.clientSecret;
11551
11550
  // update cart store checkout session with updated from checkout session payment intent creation call so the checkout session and payment intent are in sync
11552
11551
  cartStoreSetCheckoutSession(json.checkoutSessionPaymentIntentCreate);
11553
11552
  };
@@ -11624,6 +11623,7 @@ const stripeStoreUpdateCheckoutSession = async ({ adjustmentsAmount, cartId, cur
11624
11623
  adjustmentsAmount,
11625
11624
  cartId,
11626
11625
  currency,
11626
+ customerAuthenticationToken: cartStore.customerAuthenticationToken || undefined,
11627
11627
  id,
11628
11628
  itemsAmount,
11629
11629
  landedCostId,
@@ -11794,6 +11794,7 @@ const { onChange, reset, state: cartStore, } = zonosStore.createStore(() => ({
11794
11794
  checkoutTimeoutInterval: null,
11795
11795
  currency: 'USD',
11796
11796
  customQuotingError: null,
11797
+ customerAuthenticationToken: null,
11797
11798
  displayBaseCurrency: false,
11798
11799
  dutiesTaxesFees: null,
11799
11800
  dutiesTaxesFeesEstimate: null,
@@ -11946,7 +11947,11 @@ const cartStoreHasOneEligibleItem = () => {
11946
11947
  };
11947
11948
  const cartStoreSetCheckoutSession = (checkoutSession) => {
11948
11949
  var _a, _b, _c, _d, _e;
11950
+ // update stripe store with updated information
11949
11951
  stripeStore.clientSecret = checkoutSession.clientSecret;
11952
+ stripeStore.stripeCustomerSessionClientSecret =
11953
+ checkoutSession.customerSessionClientSecret;
11954
+ stripeStore.customerProfile = checkoutSession.customerProfile;
11950
11955
  cartStore.checkoutSession = checkoutSession;
11951
11956
  cartStore.checkoutSessionId = checkoutSession.id;
11952
11957
  // Check if there is a redirect URL in the metadata to override
@@ -154,6 +154,7 @@ const getAdditionalLogMetadata = () => {
154
154
  connectionEffectiveType: baseConnection === null || baseConnection === void 0 ? void 0 : baseConnection.effectiveType,
155
155
  connectionRtt: baseConnection === null || baseConnection === void 0 ? void 0 : baseConnection.rtt,
156
156
  connectionSaveData: baseConnection === null || baseConnection === void 0 ? void 0 : baseConnection.saveData,
157
+ isHostedCheckout: window.Zonos.isLegacyCheckout,
157
158
  screenHeight: window.screen.height,
158
159
  screenWidth: window.screen.width,
159
160
  userAgent: userAgentData && userAgentData.brands.length > 0
@@ -400,12 +401,15 @@ const handleRequestWithFallback = async ({ basePathType: _basePathType, options,
400
401
  log(`${path} (${duration.toFixed(2)}ms)`, 'info');
401
402
  // No need to send the load time api log for the log-script-load endpoint
402
403
  const internalDuration = response === null || response === void 0 ? void 0 : response.headers.get('Zonos-Duration');
403
- prepLoadTimeApiLog({
404
- apiPath: path,
405
- apiType: basePathType,
406
- loadTimeInternal: internalDuration ? Number(internalDuration) : 0,
407
- loadTimeTotal: duration,
408
- });
404
+ // Only record if the response status is 200, some endpoint will return 200 with error
405
+ if ((response === null || response === void 0 ? void 0 : response.status) === 200) {
406
+ prepLoadTimeApiLog({
407
+ apiPath: path,
408
+ apiType: basePathType,
409
+ loadTimeInternal: internalDuration ? Number(internalDuration) : 0,
410
+ loadTimeTotal: duration,
411
+ });
412
+ }
409
413
  const nextFallbackApiType = getNextFallbackApiType(basePathType);
410
414
  const unknownError = errors.find(({ type }) => type === 'unknown');
411
415
  const isUnknownError = !!unknownError || (response === null || response === void 0 ? void 0 : response.status) === 404;
@@ -2,8 +2,8 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- const handleFetch = require('./handleFetch-7b7f9f7c.js');
6
- const CheckoutConfig = require('./CheckoutConfig-f5e68e14.js');
5
+ const handleFetch = require('./handleFetch-ff25db40.js');
6
+ const CheckoutConfig = require('./CheckoutConfig-c5943bbf.js');
7
7
  const TaxId = require('./TaxId-4632639d.js');
8
8
 
9
9
  /**
@@ -129,7 +129,7 @@ const getZonosQaUrl = () => {
129
129
  return null;
130
130
  }
131
131
  const qaUrl = extractZonosQaUrl(window.location.href);
132
- const cdnUrl = "https://v1.3.171.js.zonos.com";
132
+ const cdnUrl = "https://v1.3.172.js.zonos.com";
133
133
  // when the qaUrl is not set and the built URL is from the test domain, use the test domain for testing
134
134
  if (!qaUrl &&
135
135
  (cdnUrl.includes('test.') ||
@@ -313,10 +313,10 @@ const zonosLoadUrl = (() => {
313
313
  }
314
314
  return null;
315
315
  })();
316
- const ZONOS_URL = "https://v1.3.171.js.zonos.com";
317
- const JS_DELIVR_ZONOS_URL = zonosLoadUrl || "https://cdn.jsdelivr.net/npm/@zonos/elements@1.3.171";
318
- const UNPKG_ZONOS_URL = "https://unpkg.com/@zonos/elements@1.3.171";
319
- const CDNJS_ZONOS_URL = "https://cdnjs.cloudflare.com/ajax/libs/zonos-elements/1.3.171";
316
+ const ZONOS_URL = "https://v1.3.172.js.zonos.com";
317
+ const JS_DELIVR_ZONOS_URL = zonosLoadUrl || "https://cdn.jsdelivr.net/npm/@zonos/elements@1.3.172";
318
+ const UNPKG_ZONOS_URL = "https://unpkg.com/@zonos/elements@1.3.172";
319
+ const CDNJS_ZONOS_URL = "https://cdnjs.cloudflare.com/ajax/libs/zonos-elements/1.3.172";
320
320
  const GOOGLE_FONT_URL = 'https://fonts.googleapis.com';
321
321
  const GOOGLE_FONT_REGEX = /^https:\/\/fonts\.googleapis\.com/;
322
322
  class Zonos {
@@ -330,7 +330,7 @@ Zonos.zonosConversionTest = typeof window !== 'undefined' &&
330
330
  !!window.location.search.match(/\?.*(&*)zonosConversionTest/);
331
331
  Zonos._paypalMockResponse = null;
332
332
  Zonos.isBigCommerce = false;
333
- Zonos.releaseDate = "1741974723741";
333
+ Zonos.releaseDate = "1742308902831";
334
334
  Zonos.isLegacyCheckout = false;
335
335
  Zonos.domain = typeof window !== 'undefined'
336
336
  ? // domain that embeds the iframe
@@ -346,7 +346,7 @@ Zonos.showBaseForeign = typeof window !== 'undefined' &&
346
346
  Zonos.isNpm = true;
347
347
  Zonos.zonosQaUrl = null;
348
348
  Zonos.zonosQaUrlApi = null;
349
- Zonos.version = `v${"1.3.171"}`;
349
+ Zonos.version = `v${"1.3.172"}`;
350
350
  Zonos.modeAlerted = false;
351
351
  Zonos.cartData = null;
352
352
  Zonos.paypal = null;
@@ -8,7 +8,7 @@ const appGlobals = require('./app-globals-3a1e7e63.js');
8
8
  const defineCustomElements = async (win, options) => {
9
9
  if (typeof window === 'undefined') return undefined;
10
10
  await appGlobals.globalScripts();
11
- return index.bootstrapLazy(JSON.parse("[[\"zonos-checkout.cjs\",[[2,\"zonos-checkout\",{\"appearanceSettingsOverride\":[16],\"preview\":[4],\"mobile\":[4],\"overrideStagingMode\":[4,\"override-staging-mode\"],\"defaultAddress\":[16],\"forceDialogOpen\":[4,\"force-dialog-open\"],\"defaultAddressParams\":[32],\"open\":[32],\"stripe\":[32],\"submitLoading\":[32],\"collapseReviewMobile\":[32],\"isAttachError\":[32],\"isMobile\":[32],\"isIframed\":[32],\"zonosReviewRef\":[32],\"storybookPaymentStatusOverride\":[32],\"isLegacyCheckout\":[32],\"confirmDialogOpen\":[32],\"isCartExpired\":[32],\"payInUsdConfirmDialogOpen\":[32],\"inventoryCheckErrorMessage\":[32],\"placedOrderInfo\":[32],\"clientSecret\":[32],\"closeDialogHandler\":[64],\"init\":[64],\"setToFinishStep\":[64],\"mockCheckoutSession\":[64]},[[16,\"zonos--init-cart-info\",\"initCartInfoHandler\"],[4,\"keydown\",\"handleKeyPress\"],[9,\"resize\",\"handleWindowResize\"]],{\"appearanceSettingsOverride\":[\"appearanceSettingsOverrideChanged\",\"handleAppearanceSettingsOverrideChange\"],\"overrideStagingMode\":[\"overrideStagingModeChanged\"],\"mobile\":[\"handleMobileChange\"],\"defaultAddress\":[\"handleAddressChange\"],\"clientSecret\":[\"handleClientSecretChange\"],\"open\":[\"handleOpenChange\"]}]]],[\"zonos-hello.cjs\",[[1,\"zonos-hello\",{\"mobileLocationOverride\":[1,\"mobile-location-override\"],\"animateFromLeftOverride\":[4,\"animate-from-left-override\"],\"appearanceSettingsOverride\":[16],\"showPeekMessage\":[32],\"zonosStoreHelloSettings\":[32],\"showDialog\":[32],\"peekMessage\":[32],\"initialUrl\":[32],\"allRestrictedItems\":[32],\"allFoundProducts\":[32],\"productsOnPage\":[32],\"isHelloWidgetRendered\":[32],\"isMobile\":[32],\"getCountryList\":[64],\"displayCurrency\":[64],\"convertAndFormat\":[64],\"convert\":[64],\"format\":[64],\"openHelloDialog\":[64]},[[9,\"resize\",\"handleResize\"]],{\"appearanceSettingsOverride\":[\"handleAppearanceSettingsOverrideChange\"]}]]],[\"zonos-controller.cjs\",[[1,\"zonos-controller\",{\"config\":[16],\"zonosApiKey\":[1,\"zonos-api-key\"],\"initCheckoutElement\":[64],\"setupGoogleFont\":[64],\"showNotification\":[64],\"reset\":[64],\"overrideConfig\":[64],\"overrideCountry\":[64],\"getAppearanceSetting\":[64],\"updateOrganizationName\":[64]},[[8,\"locationchange\",\"handleLocationChange\"]]]]],[\"zonos-tooltip.cjs\",[[1,\"zonos-tooltip\",{\"label\":[1],\"subtitle\":[1],\"showTooltip\":[32]}]]],[\"zonos-component.cjs\",[[1,\"zonos-component\",{\"first\":[1],\"middle\":[1],\"last\":[1]}]]],[\"zonos-link.cjs\",[[1,\"zonos-link\",{\"href\":[1],\"rel\":[1],\"target\":[1],\"linkTitle\":[1,\"link-title\"]}]]],[\"zonos-logo.cjs\",[[1,\"zonos-logo\",{\"theme\":[1],\"width\":[1]}]]],[\"zonos-hello-dialog.cjs\",[[1,\"zonos-hello-dialog\",{\"isOpen\":[4,\"is-open\"],\"setIsOpen\":[16],\"mobileLocationOverride\":[1,\"mobile-location-override\"],\"animateFromLeftOverride\":[4,\"animate-from-left-override\"],\"appearanceSettings\":[16],\"restrictedItems\":[16],\"welcomeMessage\":[32],\"showCountrySelect\":[32],\"showLanguageSelect\":[32]},[[4,\"click\",\"globalClickHandler\"]],{\"isOpen\":[\"isOpenHandler\"]}]]],[\"zonos-badge.cjs\",[[1,\"zonos-badge\",{\"bold\":[4],\"badgeColor\":[1,\"badge-color\"],\"icon\":[16],\"iconRight\":[4,\"icon-right\"],\"size\":[1],\"rounded\":[4],\"loading\":[4],\"dismissHandler\":[16]}]]],[\"zonos-shipping-rich-radio.cjs\",[[1,\"zonos-shipping-rich-radio\",{\"items\":[16],\"borderColor\":[1,\"border-color\"],\"borderStyle\":[1,\"border-style\"],\"theme\":[1],\"selectedItem\":[16]}]]],[\"zonos-toggle.cjs\",[[1,\"zonos-toggle\",{\"options\":[16],\"value\":[1]}]]],[\"zonos-collapse.cjs\",[[1,\"zonos-collapse\",{\"collapsed\":[4],\"collapseSize\":[2,\"collapse-size\"],\"height\":[32],\"iframe\":[32]}]]],[\"zonos-stripe-input.cjs\",[[1,\"zonos-stripe-input\",{\"inputValue\":[1,\"input-value\"],\"inputLabel\":[1,\"input-label\"],\"overridePrimaryColor\":[1,\"override-primary-color\"],\"overrideSecondaryColor\":[1,\"override-secondary-color\"],\"isDisabled\":[4,\"is-disabled\"],\"isError\":[4,\"is-error\"],\"inputPlaceholder\":[1,\"input-placeholder\"],\"value\":[1025],\"internalValue\":[32]},null,{\"inputValue\":[\"onInputValueChange\"],\"value\":[\"onValueChange\"]}]]],[\"zonos-card.cjs\",[[1,\"zonos-card\",{\"actions\":[16],\"backgroundColor\":[1,\"background-color\"],\"borderRadius\":[2,\"border-radius\"],\"footerActions\":[16],\"footerContent\":[16],\"footerHeight\":[2,\"footer-height\"],\"label\":[16],\"spacing\":[1]}]]],[\"zonos-input.cjs\",[[1,\"zonos-input\",{\"inputValue\":[1,\"input-value\"],\"inputLabel\":[1,\"input-label\"],\"inputSize\":[1,\"input-size\"],\"isDisabled\":[4,\"is-disabled\"],\"isError\":[4,\"is-error\"],\"inputPlaceholder\":[1,\"input-placeholder\"],\"value\":[32]},null,{\"inputValue\":[\"onInputValueChange\"]}]]],[\"zonos-text.cjs\",[[1,\"zonos-text\",{\"textColor\":[1,\"text-color\"],\"size\":[1],\"type\":[1],\"weight\":[2],\"ready\":[32]}]]],[\"zonos-banner.cjs\",[[1,\"zonos-banner\",{\"bannerTitle\":[1,\"banner-title\"],\"intent\":[1],\"hasContent\":[32]}]]],[\"zonos-country-flag.cjs\",[[1,\"zonos-country-flag\",{\"countryCode\":[1,\"country-code\"],\"size\":[2]}]]],[\"zonos-v-stack.cjs\",[[1,\"zonos-v-stack\",{\"spacing\":[2]}]]],[\"zonos-empty-state-payment_4.cjs\",[[1,\"zonos-empty-state-payment\",{\"emptyStateText\":[1,\"empty-state-text\"],\"theme\":[1]}],[2,\"zonos-payment\",{\"titleText\":[1,\"title-text\"],\"stripe\":[32],\"stripeElements\":[32]},null,{\"stripeElements\":[\"watchInitStripe\"],\"stripe\":[\"watchInitStripe\"]}],[2,\"zonos-paypal-payment\"],[1,\"zonos-notification\",{\"notificationArray\":[32],\"showNotification\":[64]}]]],[\"zonos-button_3.cjs\",[[17,\"zonos-button\",{\"buttonColor\":[1,\"button-color\"],\"backgroundColor\":[1,\"background-color\"],\"borderStyle\":[1,\"border-style\"],\"isDisabled\":[4,\"is-disabled\"],\"icon\":[16],\"iconRight\":[4,\"icon-right\"],\"size\":[1],\"variant\":[1],\"noBackground\":[4,\"no-background\"],\"withBoxShadow\":[4,\"with-box-shadow\"],\"noPaddingLeft\":[4,\"no-padding-left\"],\"noPaddingRight\":[4,\"no-padding-right\"],\"loading\":[4],\"justifyContent\":[1,\"justify-content\"],\"bold\":[4],\"theme\":[1],\"hasIcon\":[32],\"hasContent\":[32]},[[2,\"click\",\"clickHandler\"]],{\"icon\":[\"iconChangeHandler\"]}],[1,\"zonos-spinner\",{\"size\":[2],\"spinnerColor\":[1,\"spinner-color\"]}],[1,\"zonos-icon\",{\"autoHeight\":[4,\"auto-height\"],\"iconColor\":[1,\"icon-color\"],\"content\":[1],\"size\":[2]}]]],[\"zonos-language-select_2.cjs\",[[1,\"zonos-language-select\",{\"handleOnClose\":[16]}],[1,\"zonos-select-dialog-header\",{\"handleOnClose\":[16],\"label\":[1]}]]],[\"zonos-country-select_4.cjs\",[[1,\"zonos-country-select\",{\"handleOnClose\":[16],\"inputValue\":[32]}],[1,\"zonos-hello-dialog-footer\",{\"appearanceSettings\":[16],\"setShowCountrySelect\":[16],\"setShowLanguageSelect\":[16]}],[1,\"zonos-custom-message\",{\"icon\":[1],\"message\":[1]}],[2,\"zonos-virtual-scroll\",{\"renderItem\":[16],\"itemWidth\":[2,\"item-width\"],\"fallbackItemHeight\":[2,\"fallback-item-height\"],\"itemHeights\":[16],\"container\":[32],\"scrollTop\":[32],\"totalHeight\":[32]},null,{\"itemHeights\":[\"updateTotalHeight\"],\"fallbackItemHeight\":[\"updateTotalHeight\"]}]]],[\"zonos-address_7.cjs\",[[1,\"zonos-address-update-dialog\",{\"continueLoading\":[4,\"continue-loading\"],\"dialogLoading\":[4,\"dialog-loading\"],\"dialogOpen\":[4,\"dialog-open\"],\"submitBtnType\":[1,\"submit-btn-type\"],\"submitBtnColor\":[1,\"submit-btn-color\"],\"isMobile\":[4,\"is-mobile\"],\"shippingAddress\":[16],\"billingAddress\":[16],\"translatedShippingAddress\":[16],\"translatedBillingAddress\":[16],\"showErrorBanner\":[32],\"translatedShippingAddressState\":[32],\"translatedBillingAddressState\":[32]},null,{\"translatedShippingAddress\":[\"watchTranslatedShippingAddress\"],\"translatedBillingAddress\":[\"watchTranslatedBillingAddress\"]}],[2,\"zonos-address\",{\"type\":[1],\"titleText\":[1,\"title-text\"],\"defaultAddress\":[16],\"stripe\":[32],\"isDirtyAddress\":[32]},null,{\"stripe\":[\"watchInitStripe\"],\"defaultAddress\":[\"defaultAddressChanged\"]}],[2,\"zonos-link-authentication\",{\"titleText\":[1,\"title-text\"],\"defaultEmail\":[1,\"default-email\"],\"isEmailError\":[4,\"is-email-error\"],\"stripe\":[32],\"isStagingMode\":[32],\"clientSecret\":[32]},null,{\"isStagingMode\":[\"watchIsStagingMode\"],\"stripe\":[\"watchInitStripe\"],\"clientSecret\":[\"watchInitStripe\"],\"defaultEmail\":[\"watchDefaultEmail\"]}],[1,\"zonos-checkbox\",{\"backgroundColor\":[1,\"background-color\"],\"label\":[1],\"isChecked\":[4,\"is-checked\"],\"isDisabled\":[4,\"is-disabled\"],\"size\":[2],\"fontSize\":[1,\"font-size\"],\"borderStyle\":[1,\"border-style\"]},[[1,\"click\",\"onClick\"]]],[1,\"zonos-dialog\",{\"open\":[4],\"headerText\":[1,\"header-text\"],\"width\":[1],\"height\":[1],\"minHeight\":[1,\"min-height\"],\"noHeader\":[4,\"no-header\"],\"noBodyPadding\":[4,\"no-body-padding\"],\"noBorder\":[4,\"no-border\"],\"borderStyle\":[1,\"border-style\"],\"noCloseButton\":[4,\"no-close-button\"],\"noClickOutside\":[4,\"no-click-outside\"],\"mobile\":[4],\"isLoading\":[4,\"is-loading\"],\"isMobile\":[32]},[[9,\"resize\",\"handleWindowResize\"],[4,\"keydown\",\"handleKeyDown\"]]],[1,\"zonos-address-display\",{\"currentAddress\":[16],\"addressType\":[1,\"address-type\"]}],[1,\"zonos-address-form\",{\"currentAddress\":[16],\"translatedAddress\":[16],\"addressType\":[1,\"address-type\"],\"localAddress\":[32]},null,{\"translatedAddress\":[\"watchCurrentAddress\"]}]]],[\"zonos-cart-items_13.cjs\",[[2,\"zonos-customer-info\",{\"continueLoading\":[4,\"continue-loading\"],\"submitBtnType\":[1,\"submit-btn-type\"],\"submitBtnColor\":[1,\"submit-btn-color\"],\"isMobile\":[4,\"is-mobile\"],\"defaultAddress\":[16],\"showErrorBanner\":[32],\"shippingCountry\":[32],\"isCheckingForRestrictedItems\":[32],\"isValidatingAddress\":[32],\"isTaxIdError\":[32],\"invalidShippingCharacterList\":[32],\"invalidBillingCharacterList\":[32],\"openAddressValidationDialog\":[32],\"isEmailError\":[32]}],[2,\"zonos-checkout-payment\",{\"submitBtnType\":[1,\"submit-btn-type\"],\"continueLoading\":[4,\"continue-loading\"],\"submitBtnColor\":[1,\"submit-btn-color\"],\"isMobile\":[4,\"is-mobile\"],\"overridePrimaryColor\":[1,\"override-primary-color\"],\"showErrorBanner\":[32],\"hasStripePaymentError\":[32],\"stagingOrderCreateErrorMessage\":[32],\"internalContinueLoading\":[32]},null,{\"continueLoading\":[\"continueLoadingWatcher\"],\"hasStripePaymentError\":[\"stripePaymentErrorWatcher\"]}],[1,\"zonos-checkout-footer\",{\"mobile\":[4],\"dataTheme\":[1,\"data-theme\"],\"showLanguageDialog\":[32],\"isMobile\":[32]},[[4,\"click\",\"handleGlobalClick\"]],{\"mobile\":[\"handleMobileChange\"]}],[2,\"zonos-shipping\",{\"continueLoading\":[4,\"continue-loading\"],\"submitBtnColor\":[1,\"submit-btn-color\"],\"submitBtnType\":[1,\"submit-btn-type\"],\"selectedShippingMethod\":[32],\"collapsedDAPOptions\":[32],\"isSelecting\":[32],\"showErrorBanner\":[32],\"serviceLevelsDDP\":[32],\"serviceLevelsDAP\":[32],\"serviceLevelsOther\":[32],\"serviceLevelsAll\":[32],\"displayBaseCurrency\":[32]}],[1,\"zonos-cart-subtotal\",{\"submitBtnType\":[1,\"submit-btn-type\"],\"submitBtnColor\":[1,\"submit-btn-color\"],\"loading\":[32]}],[1,\"zonos-cart-restricted-items\",{\"hide\":[4],\"errorImages\":[32],\"internalCollapsed\":[32],\"firstRender\":[32]}],[1,\"zonos-checkout-finish\",{\"borderRadius\":[1,\"border-radius\"],\"storybookForceStatus\":[1,\"storybook-force-status\"],\"overrideNotification\":[16],\"isLoading\":[32],\"notificationType\":[32],\"notificationTitle\":[32],\"notificationMessages\":[32],\"notificationActionText\":[32],\"order\":[32],\"isWaitingToRedirect\":[32]}],[1,\"zonos-confirm-dialog\",{\"dialogTitle\":[1,\"dialog-title\"],\"dialogIntent\":[1,\"dialog-intent\"],\"dialogSubtitle\":[1,\"dialog-subtitle\"],\"submitBtnColor\":[1,\"submit-btn-color\"],\"dialogConfirmBtnText\":[1,\"dialog-confirm-btn-text\"],\"dialogWidth\":[2,\"dialog-width\"],\"dialogCancelBtnText\":[1,\"dialog-cancel-btn-text\"],\"dialogType\":[1,\"dialog-type\"],\"isMobile\":[4,\"is-mobile\"],\"dialogOpen\":[4,\"dialog-open\"],\"noClickOutside\":[4,\"no-click-outside\"]},[[4,\"keydown\",\"handleKeyDown\"]]],[1,\"zonos-checkout-progress-tabs\",{\"tabColor\":[1,\"tab-color\"],\"backgroundColor\":[1,\"background-color\"],\"setTabItems\":[64],\"setTabSelected\":[64]}],[1,\"zonos-review\",{\"mobile\":[4],\"collapsed\":[4],\"isMobile\":[32]},[[9,\"resize\",\"handleWindowResize\"]]],[1,\"zonos-cart-items\",{\"errorImages\":[32]}],[1,\"zonos-currency-toggle\",{\"errorImages\":[32]}],[1,\"zonos-rest-state\",{\"restStateSubtitle\":[1,\"rest-state-subtitle\"],\"restStateTitle\":[1,\"rest-state-title\"],\"restStateType\":[1,\"rest-state-type\"],\"isErrorImageLoad\":[32]}]]]]"), options);
11
+ return index.bootstrapLazy(JSON.parse("[[\"zonos-checkout.cjs\",[[2,\"zonos-checkout\",{\"appearanceSettingsOverride\":[16],\"preview\":[4],\"mobile\":[4],\"overrideStagingMode\":[4,\"override-staging-mode\"],\"defaultAddress\":[16],\"forceDialogOpen\":[4,\"force-dialog-open\"],\"defaultAddressParams\":[32],\"defaultCustomerProfileAddress\":[32],\"customerProfile\":[32],\"open\":[32],\"stripe\":[32],\"submitLoading\":[32],\"collapseReviewMobile\":[32],\"isAttachError\":[32],\"isMobile\":[32],\"isIframed\":[32],\"zonosReviewRef\":[32],\"storybookPaymentStatusOverride\":[32],\"isLegacyCheckout\":[32],\"confirmDialogOpen\":[32],\"isCartExpired\":[32],\"payInUsdConfirmDialogOpen\":[32],\"inventoryCheckErrorMessage\":[32],\"placedOrderInfo\":[32],\"clientSecret\":[32],\"stripeCustomerSessionClientSecret\":[32],\"closeDialogHandler\":[64],\"init\":[64],\"setToFinishStep\":[64],\"mockCheckoutSession\":[64]},[[16,\"zonos--init-cart-info\",\"initCartInfoHandler\"],[4,\"keydown\",\"handleKeyPress\"],[9,\"resize\",\"handleWindowResize\"]],{\"appearanceSettingsOverride\":[\"appearanceSettingsOverrideChanged\",\"handleAppearanceSettingsOverrideChange\"],\"overrideStagingMode\":[\"overrideStagingModeChanged\"],\"mobile\":[\"handleMobileChange\"],\"defaultAddress\":[\"handleAddressChange\"],\"customerProfile\":[\"handleCustomerProfileChange\"],\"clientSecret\":[\"handleClientSecretChange\"],\"stripeCustomerSessionClientSecret\":[\"handleClientSecretChange\"],\"open\":[\"handleOpenChange\"]}]]],[\"zonos-hello.cjs\",[[1,\"zonos-hello\",{\"mobileLocationOverride\":[1,\"mobile-location-override\"],\"animateFromLeftOverride\":[4,\"animate-from-left-override\"],\"appearanceSettingsOverride\":[16],\"showPeekMessage\":[32],\"zonosStoreHelloSettings\":[32],\"showDialog\":[32],\"peekMessage\":[32],\"initialUrl\":[32],\"allRestrictedItems\":[32],\"allFoundProducts\":[32],\"productsOnPage\":[32],\"isHelloWidgetRendered\":[32],\"isMobile\":[32],\"getCountryList\":[64],\"displayCurrency\":[64],\"convertAndFormat\":[64],\"convert\":[64],\"format\":[64],\"openHelloDialog\":[64]},[[9,\"resize\",\"handleResize\"]],{\"appearanceSettingsOverride\":[\"handleAppearanceSettingsOverrideChange\"]}]]],[\"zonos-controller.cjs\",[[1,\"zonos-controller\",{\"config\":[16],\"zonosApiKey\":[1,\"zonos-api-key\"],\"initCheckoutElement\":[64],\"setupGoogleFont\":[64],\"showNotification\":[64],\"reset\":[64],\"overrideConfig\":[64],\"overrideCountry\":[64],\"getAppearanceSetting\":[64],\"updateOrganizationName\":[64]},[[8,\"locationchange\",\"handleLocationChange\"]]]]],[\"zonos-tooltip.cjs\",[[1,\"zonos-tooltip\",{\"label\":[1],\"subtitle\":[1],\"showTooltip\":[32]}]]],[\"zonos-component.cjs\",[[1,\"zonos-component\",{\"first\":[1],\"middle\":[1],\"last\":[1]}]]],[\"zonos-link.cjs\",[[1,\"zonos-link\",{\"href\":[1],\"rel\":[1],\"target\":[1],\"linkTitle\":[1,\"link-title\"]}]]],[\"zonos-logo.cjs\",[[1,\"zonos-logo\",{\"theme\":[1],\"width\":[1]}]]],[\"zonos-hello-dialog.cjs\",[[1,\"zonos-hello-dialog\",{\"isOpen\":[4,\"is-open\"],\"setIsOpen\":[16],\"mobileLocationOverride\":[1,\"mobile-location-override\"],\"animateFromLeftOverride\":[4,\"animate-from-left-override\"],\"appearanceSettings\":[16],\"restrictedItems\":[16],\"welcomeMessage\":[32],\"showCountrySelect\":[32],\"showLanguageSelect\":[32]},[[4,\"click\",\"globalClickHandler\"]],{\"isOpen\":[\"isOpenHandler\"]}]]],[\"zonos-badge.cjs\",[[1,\"zonos-badge\",{\"bold\":[4],\"badgeColor\":[1,\"badge-color\"],\"icon\":[16],\"iconRight\":[4,\"icon-right\"],\"size\":[1],\"rounded\":[4],\"loading\":[4],\"dismissHandler\":[16]}]]],[\"zonos-shipping-rich-radio.cjs\",[[1,\"zonos-shipping-rich-radio\",{\"items\":[16],\"borderColor\":[1,\"border-color\"],\"borderStyle\":[1,\"border-style\"],\"theme\":[1],\"selectedItem\":[16]}]]],[\"zonos-toggle.cjs\",[[1,\"zonos-toggle\",{\"options\":[16],\"value\":[1]}]]],[\"zonos-collapse.cjs\",[[1,\"zonos-collapse\",{\"collapsed\":[4],\"collapseSize\":[2,\"collapse-size\"],\"height\":[32],\"iframe\":[32]}]]],[\"zonos-stripe-input.cjs\",[[1,\"zonos-stripe-input\",{\"inputValue\":[1,\"input-value\"],\"inputLabel\":[1,\"input-label\"],\"overridePrimaryColor\":[1,\"override-primary-color\"],\"overrideSecondaryColor\":[1,\"override-secondary-color\"],\"isDisabled\":[4,\"is-disabled\"],\"isError\":[4,\"is-error\"],\"inputPlaceholder\":[1,\"input-placeholder\"],\"value\":[1025],\"internalValue\":[32]},null,{\"inputValue\":[\"onInputValueChange\"],\"value\":[\"onValueChange\"]}]]],[\"zonos-card.cjs\",[[1,\"zonos-card\",{\"actions\":[16],\"backgroundColor\":[1,\"background-color\"],\"borderRadius\":[2,\"border-radius\"],\"footerActions\":[16],\"footerContent\":[16],\"footerHeight\":[2,\"footer-height\"],\"label\":[16],\"spacing\":[1]}]]],[\"zonos-input.cjs\",[[1,\"zonos-input\",{\"inputValue\":[1,\"input-value\"],\"inputLabel\":[1,\"input-label\"],\"inputSize\":[1,\"input-size\"],\"isDisabled\":[4,\"is-disabled\"],\"isError\":[4,\"is-error\"],\"inputPlaceholder\":[1,\"input-placeholder\"],\"value\":[32]},null,{\"inputValue\":[\"onInputValueChange\"]}]]],[\"zonos-text.cjs\",[[1,\"zonos-text\",{\"textColor\":[1,\"text-color\"],\"size\":[1],\"type\":[1],\"weight\":[2],\"ready\":[32]}]]],[\"zonos-banner.cjs\",[[1,\"zonos-banner\",{\"bannerTitle\":[1,\"banner-title\"],\"intent\":[1],\"hasContent\":[32]}]]],[\"zonos-country-flag.cjs\",[[1,\"zonos-country-flag\",{\"countryCode\":[1,\"country-code\"],\"size\":[2]}]]],[\"zonos-v-stack.cjs\",[[1,\"zonos-v-stack\",{\"spacing\":[2]}]]],[\"zonos-empty-state-payment_4.cjs\",[[1,\"zonos-empty-state-payment\",{\"emptyStateText\":[1,\"empty-state-text\"],\"theme\":[1]}],[2,\"zonos-payment\",{\"titleText\":[1,\"title-text\"],\"stripe\":[32],\"stripeElements\":[32]},null,{\"stripeElements\":[\"watchInitStripe\"],\"stripe\":[\"watchInitStripe\"]}],[2,\"zonos-paypal-payment\"],[1,\"zonos-notification\",{\"notificationArray\":[32],\"showNotification\":[64]}]]],[\"zonos-button_3.cjs\",[[17,\"zonos-button\",{\"buttonColor\":[1,\"button-color\"],\"backgroundColor\":[1,\"background-color\"],\"borderStyle\":[1,\"border-style\"],\"isDisabled\":[4,\"is-disabled\"],\"icon\":[16],\"iconRight\":[4,\"icon-right\"],\"size\":[1],\"variant\":[1],\"noBackground\":[4,\"no-background\"],\"withBoxShadow\":[4,\"with-box-shadow\"],\"noPaddingLeft\":[4,\"no-padding-left\"],\"noPaddingRight\":[4,\"no-padding-right\"],\"loading\":[4],\"justifyContent\":[1,\"justify-content\"],\"bold\":[4],\"theme\":[1],\"hasIcon\":[32],\"hasContent\":[32]},[[2,\"click\",\"clickHandler\"]],{\"icon\":[\"iconChangeHandler\"]}],[1,\"zonos-spinner\",{\"size\":[2],\"spinnerColor\":[1,\"spinner-color\"]}],[1,\"zonos-icon\",{\"autoHeight\":[4,\"auto-height\"],\"iconColor\":[1,\"icon-color\"],\"content\":[1],\"size\":[2]}]]],[\"zonos-language-select_2.cjs\",[[1,\"zonos-language-select\",{\"handleOnClose\":[16]}],[1,\"zonos-select-dialog-header\",{\"handleOnClose\":[16],\"label\":[1]}]]],[\"zonos-country-select_4.cjs\",[[1,\"zonos-country-select\",{\"handleOnClose\":[16],\"inputValue\":[32]}],[1,\"zonos-hello-dialog-footer\",{\"appearanceSettings\":[16],\"setShowCountrySelect\":[16],\"setShowLanguageSelect\":[16]}],[1,\"zonos-custom-message\",{\"icon\":[1],\"message\":[1]}],[2,\"zonos-virtual-scroll\",{\"renderItem\":[16],\"itemWidth\":[2,\"item-width\"],\"fallbackItemHeight\":[2,\"fallback-item-height\"],\"itemHeights\":[16],\"container\":[32],\"scrollTop\":[32],\"totalHeight\":[32]},null,{\"itemHeights\":[\"updateTotalHeight\"],\"fallbackItemHeight\":[\"updateTotalHeight\"]}]]],[\"zonos-address_7.cjs\",[[1,\"zonos-address-update-dialog\",{\"continueLoading\":[4,\"continue-loading\"],\"dialogLoading\":[4,\"dialog-loading\"],\"dialogOpen\":[4,\"dialog-open\"],\"submitBtnType\":[1,\"submit-btn-type\"],\"submitBtnColor\":[1,\"submit-btn-color\"],\"isMobile\":[4,\"is-mobile\"],\"shippingAddress\":[16],\"billingAddress\":[16],\"translatedShippingAddress\":[16],\"translatedBillingAddress\":[16],\"showErrorBanner\":[32],\"translatedShippingAddressState\":[32],\"translatedBillingAddressState\":[32]},null,{\"translatedShippingAddress\":[\"watchTranslatedShippingAddress\"],\"translatedBillingAddress\":[\"watchTranslatedBillingAddress\"]}],[2,\"zonos-address\",{\"type\":[1],\"titleText\":[1,\"title-text\"],\"defaultAddress\":[16],\"stripe\":[32],\"isDirtyAddress\":[32]},null,{\"stripe\":[\"watchInitStripe\"],\"defaultAddress\":[\"defaultAddressChanged\"]}],[2,\"zonos-link-authentication\",{\"titleText\":[1,\"title-text\"],\"defaultEmail\":[1,\"default-email\"],\"isEmailError\":[4,\"is-email-error\"],\"stripe\":[32],\"isStagingMode\":[32],\"clientSecret\":[32]},null,{\"isStagingMode\":[\"watchIsStagingMode\"],\"stripe\":[\"watchInitStripe\"],\"clientSecret\":[\"watchInitStripe\"],\"defaultEmail\":[\"watchDefaultEmail\"]}],[1,\"zonos-checkbox\",{\"backgroundColor\":[1,\"background-color\"],\"label\":[1],\"isChecked\":[4,\"is-checked\"],\"isDisabled\":[4,\"is-disabled\"],\"size\":[2],\"fontSize\":[1,\"font-size\"],\"borderStyle\":[1,\"border-style\"]},[[1,\"click\",\"onClick\"]]],[1,\"zonos-dialog\",{\"open\":[4],\"headerText\":[1,\"header-text\"],\"width\":[1],\"height\":[1],\"minHeight\":[1,\"min-height\"],\"noHeader\":[4,\"no-header\"],\"noBodyPadding\":[4,\"no-body-padding\"],\"noBorder\":[4,\"no-border\"],\"borderStyle\":[1,\"border-style\"],\"noCloseButton\":[4,\"no-close-button\"],\"noClickOutside\":[4,\"no-click-outside\"],\"mobile\":[4],\"isLoading\":[4,\"is-loading\"],\"isMobile\":[32]},[[9,\"resize\",\"handleWindowResize\"],[4,\"keydown\",\"handleKeyDown\"]]],[1,\"zonos-address-display\",{\"currentAddress\":[16],\"addressType\":[1,\"address-type\"]}],[1,\"zonos-address-form\",{\"currentAddress\":[16],\"translatedAddress\":[16],\"addressType\":[1,\"address-type\"],\"localAddress\":[32]},null,{\"translatedAddress\":[\"watchCurrentAddress\"]}]]],[\"zonos-cart-items_13.cjs\",[[2,\"zonos-customer-info\",{\"continueLoading\":[4,\"continue-loading\"],\"submitBtnType\":[1,\"submit-btn-type\"],\"submitBtnColor\":[1,\"submit-btn-color\"],\"isMobile\":[4,\"is-mobile\"],\"defaultAddress\":[16],\"showErrorBanner\":[32],\"shippingCountry\":[32],\"isCheckingForRestrictedItems\":[32],\"isValidatingAddress\":[32],\"isTaxIdError\":[32],\"invalidShippingCharacterList\":[32],\"invalidBillingCharacterList\":[32],\"openAddressValidationDialog\":[32],\"isEmailError\":[32]}],[2,\"zonos-checkout-payment\",{\"submitBtnType\":[1,\"submit-btn-type\"],\"continueLoading\":[4,\"continue-loading\"],\"submitBtnColor\":[1,\"submit-btn-color\"],\"isMobile\":[4,\"is-mobile\"],\"overridePrimaryColor\":[1,\"override-primary-color\"],\"showErrorBanner\":[32],\"hasStripePaymentError\":[32],\"stagingOrderCreateErrorMessage\":[32],\"internalContinueLoading\":[32]},null,{\"continueLoading\":[\"continueLoadingWatcher\"],\"hasStripePaymentError\":[\"stripePaymentErrorWatcher\"]}],[1,\"zonos-checkout-footer\",{\"mobile\":[4],\"dataTheme\":[1,\"data-theme\"],\"showLanguageDialog\":[32],\"isMobile\":[32]},[[4,\"click\",\"handleGlobalClick\"]],{\"mobile\":[\"handleMobileChange\"]}],[2,\"zonos-shipping\",{\"continueLoading\":[4,\"continue-loading\"],\"submitBtnColor\":[1,\"submit-btn-color\"],\"submitBtnType\":[1,\"submit-btn-type\"],\"selectedShippingMethod\":[32],\"collapsedDAPOptions\":[32],\"isSelecting\":[32],\"showErrorBanner\":[32],\"serviceLevelsDDP\":[32],\"serviceLevelsDAP\":[32],\"serviceLevelsOther\":[32],\"serviceLevelsAll\":[32],\"displayBaseCurrency\":[32]}],[1,\"zonos-cart-subtotal\",{\"submitBtnType\":[1,\"submit-btn-type\"],\"submitBtnColor\":[1,\"submit-btn-color\"],\"loading\":[32]}],[1,\"zonos-cart-restricted-items\",{\"hide\":[4],\"errorImages\":[32],\"internalCollapsed\":[32],\"firstRender\":[32]}],[1,\"zonos-checkout-finish\",{\"borderRadius\":[1,\"border-radius\"],\"storybookForceStatus\":[1,\"storybook-force-status\"],\"overrideNotification\":[16],\"isLoading\":[32],\"notificationType\":[32],\"notificationTitle\":[32],\"notificationMessages\":[32],\"notificationActionText\":[32],\"order\":[32],\"isWaitingToRedirect\":[32]}],[1,\"zonos-confirm-dialog\",{\"dialogTitle\":[1,\"dialog-title\"],\"dialogIntent\":[1,\"dialog-intent\"],\"dialogSubtitle\":[1,\"dialog-subtitle\"],\"submitBtnColor\":[1,\"submit-btn-color\"],\"dialogConfirmBtnText\":[1,\"dialog-confirm-btn-text\"],\"dialogWidth\":[2,\"dialog-width\"],\"dialogCancelBtnText\":[1,\"dialog-cancel-btn-text\"],\"dialogType\":[1,\"dialog-type\"],\"isMobile\":[4,\"is-mobile\"],\"dialogOpen\":[4,\"dialog-open\"],\"noClickOutside\":[4,\"no-click-outside\"]},[[4,\"keydown\",\"handleKeyDown\"]]],[1,\"zonos-checkout-progress-tabs\",{\"tabColor\":[1,\"tab-color\"],\"backgroundColor\":[1,\"background-color\"],\"setTabItems\":[64],\"setTabSelected\":[64]}],[1,\"zonos-review\",{\"mobile\":[4],\"collapsed\":[4],\"isMobile\":[32]},[[9,\"resize\",\"handleWindowResize\"]]],[1,\"zonos-cart-items\",{\"errorImages\":[32]}],[1,\"zonos-currency-toggle\",{\"errorImages\":[32]}],[1,\"zonos-rest-state\",{\"restStateSubtitle\":[1,\"rest-state-subtitle\"],\"restStateTitle\":[1,\"rest-state-title\"],\"restStateType\":[1,\"rest-state-type\"],\"isErrorImageLoad\":[32]}]]]]"), options);
12
12
  };
13
13
 
14
14
  exports.setNonce = index.setNonce;
@@ -1,8 +1,8 @@
1
1
  'use strict';
2
2
 
3
3
  const zonosStore = require('./zonosStore-3812b318.js');
4
- const cart = require('./cart-36799bbe.js');
5
- const handleFetch = require('./handleFetch-7b7f9f7c.js');
4
+ const cart = require('./cart-d91d9507.js');
5
+ const handleFetch = require('./handleFetch-ff25db40.js');
6
6
  const isDarkColor = require('./isDarkColor-ec4a4e7d.js');
7
7
 
8
8
  /*!
@@ -3,10 +3,10 @@
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
5
  const index = require('./index-2f90486e.js');
6
- const cart = require('./cart-36799bbe.js');
6
+ const cart = require('./cart-d91d9507.js');
7
7
  const zonosStore = require('./zonosStore-3812b318.js');
8
8
  const isCheckoutMobile = require('./isCheckoutMobile-f491ca7c.js');
9
- const handleFetch = require('./handleFetch-7b7f9f7c.js');
9
+ const handleFetch = require('./handleFetch-ff25db40.js');
10
10
  const containsNonLatinChars = require('./containsNonLatinChars-2be5129b.js');
11
11
  const classes = require('./classes-b7918f56.js');
12
12
  const RemoveIcon$1 = require('./RemoveIcon-081ac073.js');
@@ -26,7 +26,7 @@ const ZonosAddress = class {
26
26
  this.isAutoCompleteAdjusted = false;
27
27
  this.type = undefined;
28
28
  this.titleText = undefined;
29
- this.defaultAddress = null;
29
+ this.defaultAddress = [];
30
30
  this.stripe = window.Zonos.stripe;
31
31
  this.isDirtyAddress = false;
32
32
  }
@@ -62,19 +62,15 @@ const ZonosAddress = class {
62
62
  cart.stripeStore.stripeBillingAddressElement = stripeAddressElement;
63
63
  }
64
64
  async watchInitStripe() {
65
- var _a, _b;
66
65
  this.stripe = window.Zonos.stripe;
67
66
  const { stripeAddressEventData, stripeElements } = this.getStripeAddressInstance();
68
67
  if (!this.stripe || !stripeElements) {
69
68
  handleFetch.logError("Stripe is not initialized. Couldn't load stripe element.");
70
69
  return;
71
70
  }
72
- const phone = (_a = this.defaultAddress) === null || _a === void 0 ? void 0 : _a.phone;
73
- if (!phone) {
74
- // remove phone from default address if it's not provided, stripe
75
- // will throw error if key phone exist and its value is empty or 'undefined'.
76
- (_b = this.defaultAddress) === null || _b === void 0 ? true : delete _b.phone;
77
- }
71
+ // remove phone from default address if it's not provided, stripe
72
+ // will throw error if key phone exist and its value is empty or 'undefined'.
73
+ const defaultAddress = this.defaultAddress.map(address => (Object.assign(Object.assign({}, address), { name: address.name, phone: address.phone || undefined })));
78
74
  const shippableCountries = cart.localizationStore.shippingZoneCountries;
79
75
  const shippingZone = shippableCountries
80
76
  ? Object.values(shippableCountries).map(country => country.code)
@@ -88,8 +84,8 @@ const ZonosAddress = class {
88
84
  const addressElement = stripeElements.create('address', {
89
85
  allowedCountries: checkoutAllCountries ? [] : allowedCountries,
90
86
  // only show the default address if stripeAddressEventData is not provided
91
- contacts: this.defaultAddress && !stripeAddressEventData
92
- ? [this.defaultAddress]
87
+ contacts: defaultAddress.length && !stripeAddressEventData
88
+ ? this.defaultAddress
93
89
  : [],
94
90
  defaultValues: {
95
91
  address: Object.assign(Object.assign({}, stripeAddressEventData === null || stripeAddressEventData === void 0 ? void 0 : stripeAddressEventData.value.address), { country: defaultAddressCountry }),
@@ -147,12 +143,27 @@ const ZonosAddress = class {
147
143
  type: this.type,
148
144
  });
149
145
  }
150
- defaultAddressChanged() {
146
+ defaultAddressChanged(oldAddress, newAddress) {
147
+ // check if stringified json of oldAddress is different from newAddress
148
+ const oldAddressString = JSON.stringify(oldAddress);
149
+ const newAddressString = JSON.stringify(newAddress);
150
+ // No need to reset address element if the default address is the same
151
+ if (oldAddressString === newAddressString) {
152
+ return;
153
+ }
151
154
  handleFetch.log('Reset address element when default address property is changed', 'info', {
152
155
  defaultAddress: this.defaultAddress,
153
156
  });
154
157
  const stripeElement = this.getStripeAddressInstance().stripeAddressElement;
158
+ stripeElement === null || stripeElement === void 0 ? void 0 : stripeElement.clear();
155
159
  stripeElement === null || stripeElement === void 0 ? void 0 : stripeElement.destroy();
160
+ // Reset stripe address event data
161
+ if (this.type === 'shipping') {
162
+ cart.stripeStore.stripeAddressEventData = null;
163
+ }
164
+ else {
165
+ cart.stripeStore.stripeBillingAddressEventData = null;
166
+ }
156
167
  void this.watchInitStripe();
157
168
  }
158
169
  renderCompanyNameInput() {
@@ -186,7 +197,7 @@ const ZonosAddress = class {
186
197
  }
187
198
  render() {
188
199
  // this component loads iframe from the stripe elements and puts here, so we don't need to do anything here
189
- return (index.h(index.Host, { key: '18d2602886588dfeb39c7c0386354671076dd9bf', class: "zonos--address zonos--elements" }, index.h("zonos-text", { key: '9c4f704259e307932930995b14a9f2edd51dd3e3', class: "zonos--title", type: "semiBoldLabel" }, this.titleText), this.renderCompanyNameInput(), index.h("div", { key: '7b2031b0b29cc8153b9b6376f27ccd331cc46e7a', class: "zonos--address-component" })));
200
+ return (index.h(index.Host, { key: '455356fe5ca9910fe34df12eb02b499316167bc7', class: "zonos--address zonos--elements" }, index.h("zonos-text", { key: '44ae4b872ca4aea9e9d8e1cfa0de5e421e4ea524', class: "zonos--title", type: "semiBoldLabel" }, this.titleText), this.renderCompanyNameInput(), index.h("div", { key: '188976d8eef8c23b41c1b82fc7d5c4d2069fc92b', class: "zonos--address-component" })));
190
201
  }
191
202
  get el() { return index.getElement(this); }
192
203
  static get watchers() { return {
@@ -634,7 +645,7 @@ const ZonosLinkAuthentication = class {
634
645
  // Create and mount the Authentication Element in ${type} mode
635
646
  const linkAuthenticationElement = cart.stripeStore.stripeLinkElement ||
636
647
  cart.stripeStore.stripeElements.create('linkAuthentication', {
637
- defaultValues: defaultValues || undefined,
648
+ defaultValues: defaultValues,
638
649
  });
639
650
  const linkAuthenticationElementContainer = this.el.querySelector('.zonos--link-authentication-component');
640
651
  if (!linkAuthenticationElementContainer) {
@@ -649,11 +660,33 @@ const ZonosLinkAuthentication = class {
649
660
  });
650
661
  cart.stripeStore.stripeLinkElement = linkAuthenticationElement;
651
662
  }
652
- watchDefaultEmail() {
653
- if (!this.defaultEmail) {
663
+ watchDefaultEmail(newDefaultEmail, oldDefaultEmail) {
664
+ var _a, _b;
665
+ handleFetch.log('Default email is changed', 'info', {
666
+ newDefaultEmail,
667
+ oldDefaultEmail,
668
+ });
669
+ if (oldDefaultEmail === newDefaultEmail) {
654
670
  return;
655
671
  }
656
- this.setCustomEmailInputToLinkEvent(this.defaultEmail);
672
+ if (!newDefaultEmail) {
673
+ cart.stripeStore.stripeLinkEventData = null;
674
+ }
675
+ // Only set value for Stripe input input to stripeLinkEventData when checkout is in staging mode
676
+ if (cart.cartStore.isStagingMode) {
677
+ this.setCustomEmailInputToLinkEvent(newDefaultEmail || '');
678
+ return;
679
+ }
680
+ (_a = cart.stripeStore.stripeLinkElement) === null || _a === void 0 ? void 0 : _a.clear();
681
+ (_b = cart.stripeStore.stripeLinkElement) === null || _b === void 0 ? void 0 : _b.destroy();
682
+ cart.stripeStore.stripeLinkElement = null;
683
+ cart.stripeStore.stripeLinkEventData = null;
684
+ handleFetch.log('Reset stripe link element when default email is changed', 'info', {
685
+ defaultEmail: newDefaultEmail,
686
+ });
687
+ setTimeout(() => {
688
+ void this.watchInitStripe();
689
+ }, 5);
657
690
  }
658
691
  componentDidLoad() {
659
692
  // @Watch doesn't get trigger on initial load
@@ -3,11 +3,11 @@
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
5
  const index = require('./index-2f90486e.js');
6
- const cart = require('./cart-36799bbe.js');
6
+ const cart = require('./cart-d91d9507.js');
7
7
  const classes = require('./classes-b7918f56.js');
8
- const paypal = require('./paypal-3eae38bd.js');
8
+ const paypal = require('./paypal-82841277.js');
9
9
  const zonosStore = require('./zonosStore-3812b318.js');
10
- const handleFetch = require('./handleFetch-7b7f9f7c.js');
10
+ const handleFetch = require('./handleFetch-ff25db40.js');
11
11
  const createCustomEvent = require('./createCustomEvent-7b6fad95.js');
12
12
  const getBorderRadius = require('./getBorderRadius-94ef609c.js');
13
13
  const isCheckoutMobile = require('./isCheckoutMobile-f491ca7c.js');
@@ -2339,7 +2339,7 @@ const ZonosCustomerInfo = class {
2339
2339
  this.submitBtnType = undefined;
2340
2340
  this.submitBtnColor = undefined;
2341
2341
  this.isMobile = false;
2342
- this.defaultAddress = null;
2342
+ this.defaultAddress = [];
2343
2343
  this.showErrorBanner = false;
2344
2344
  this.shippingCountry = '';
2345
2345
  this.isCheckingForRestrictedItems = false;
@@ -2396,7 +2396,7 @@ const ZonosCustomerInfo = class {
2396
2396
  } }), this.isTaxIdError && (index.h("zonos-text", { textColor: 'red-600', type: "caption" }, cart.translate('Tax id is required')))));
2397
2397
  }
2398
2398
  render() {
2399
- var _a, _b;
2399
+ var _a, _b, _c, _d, _e, _f;
2400
2400
  if (!cart.stripeStore.stripeElements) {
2401
2401
  return null;
2402
2402
  }
@@ -2415,11 +2415,15 @@ const ZonosCustomerInfo = class {
2415
2415
  const showBilling = !cart.stripeStore.stripeShippingSameAsBilling;
2416
2416
  // Get theme for the update dialog, inherit from the theme, no from this component theme
2417
2417
  const theme = zonosStore.getZonosStoreTheme(zonosStore.zonosStore.appearance.theme);
2418
+ // Attempt to get the email from email from customer profile's locations, if not provided, just use the email from root customer profile
2419
+ const defaultEmail = ((_b = this.defaultAddress.find(Boolean)) === null || _b === void 0 ? void 0 : _b.email) ||
2420
+ ((_e = (_d = (_c = cart.stripeStore.customerProfile) === null || _c === void 0 ? void 0 : _c.locations) === null || _d === void 0 ? void 0 : _d.find(Boolean)) === null || _e === void 0 ? void 0 : _e.email) ||
2421
+ ((_f = cart.stripeStore.customerProfile) === null || _f === void 0 ? void 0 : _f.email);
2418
2422
  // start validate on typing after error banner is shown, and hide it if the form is complete
2419
2423
  if (this.showErrorBanner) {
2420
2424
  this.showErrorBanner = !this.handleValidate();
2421
2425
  }
2422
- return (index.h(index.Host, { class: "zonos--customer-info zonos--elements" }, index.h("div", { class: "zonos--group" }, index.h("zonos-text", { class: "zonos--title", type: "semiBoldSubheader" }, cart.translate('Customer information')), this.showErrorBanner && (index.h("zonos-banner", { class: "zonos--error-banner", intent: "error" }, cart.translate('Missing required fields. Make sure all fields are completed.'))), index.h("zonos-link-authentication", { defaultEmail: (_b = this.defaultAddress) === null || _b === void 0 ? void 0 : _b.email, isEmailError: this.isEmailError, onLinkAuthenticationChange: this.handleEmailValidation, titleText: cart.translate('Contact') }), index.h("zonos-address", { defaultAddress: this.defaultAddress, titleText: cart.translate('Address'), type: "shipping" }), this.renderTaxIdInput(this.shippingCountry), index.h("zonos-checkbox", { class: "zonos--shipping-same-as-billing-cbx", isChecked: cart.stripeStore.stripeShippingSameAsBilling, label: cart.translate('Shipping address same as billing'), onCheckboxSelected: e => {
2426
+ return (index.h(index.Host, { class: "zonos--customer-info zonos--elements" }, index.h("div", { class: "zonos--group" }, index.h("zonos-text", { class: "zonos--title", type: "semiBoldSubheader" }, cart.translate('Customer information')), this.showErrorBanner && (index.h("zonos-banner", { class: "zonos--error-banner", intent: "error" }, cart.translate('Missing required fields. Make sure all fields are completed.'))), index.h("zonos-link-authentication", { defaultEmail: defaultEmail, isEmailError: this.isEmailError, onLinkAuthenticationChange: this.handleEmailValidation, titleText: cart.translate('Contact') }), index.h("zonos-address", { defaultAddress: this.defaultAddress, titleText: cart.translate('Address'), type: "shipping" }), this.renderTaxIdInput(this.shippingCountry), index.h("zonos-checkbox", { class: "zonos--shipping-same-as-billing-cbx", isChecked: cart.stripeStore.stripeShippingSameAsBilling, label: cart.translate('Shipping address same as billing'), onCheckboxSelected: e => {
2423
2427
  cart.stripeStore.stripeShippingSameAsBilling = e.detail;
2424
2428
  } }), index.h("zonos-collapse", { collapsed: !showBilling }, index.h("zonos-address", { defaultAddress: this.defaultAddress, titleText: cart.translate('Billing address'), type: "billing" })), index.h("div", { class: "zonos--group-btn" }, index.h("zonos-button", { backgroundColor: this.submitBtnColor, bold: true, loading: this.continueLoading, onClick: () => this.continueClickHandler(), size: "lg",
2425
2429
  // use primary type when on mobile mode